Improve create placeholder#199
Conversation
| inline static LARGE_INTEGER FileTimeToLargeInteger(_In_ const FILETIME fileTime) | ||
| { | ||
| inline static LARGE_INTEGER JsTimestampToLargeInteger(int64_t jsTimestamp) { | ||
| const int64_t EPOCH_DIFFERENCE = 11644473600000LL; |
There was a problem hiding this comment.
This was done in a function in javascript:
private convertToWindowsTime(jsTime: number) {
return BigInt(jsTime) * 10000n + 116444736000000000n;
}However, now we move all conversations from the date number in javascript to C++.
| return result; | ||
| } | ||
|
|
||
| if (isDirectory) // TODO: the function createEntry is used to create only folders (directories), so this if is always true |
There was a problem hiding this comment.
Here we have just removed the if as the TODO says. This was just used only for folders.
| L"Unable to free up space because the file is currently in use.\nPlease close the file and try again.", | ||
| L"File in use", | ||
| MB_OK | MB_ICONWARNING | MB_SYSTEMMODAL); | ||
| // MessageBoxW( |
There was a problem hiding this comment.
This was the MessageBox displayed when a file was in used, however, currently we have some files that are locked and this MessageBox is displayed everytime. This error is already in prod, for now we just log it and ignore.
| @@ -1,93 +1,25 @@ | |||
| #include <Windows.h> | |||
There was a problem hiding this comment.
Here we just replace all parse values with the new template napi_extract_args and convert the datetime values to a windows format (LARGE_INTEGER).
| @@ -1,94 +1,24 @@ | |||
| #include <Windows.h> | |||
There was a problem hiding this comment.
Here we just replace all parse values with the new template napi_extract_args and convert the datetime values to a windows format (LARGE_INTEGER).
|




What
Improve the args handler in create file and folder placeholder and also remove some args that were not used, like itemAttributes.